/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ui.admin;

import hibernate.dao.RoleDAO;
import java.io.IOException;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.servlet.http.HttpServletRequest;
import org.hibernate.Query;
import org.hibernate.Session;
import org.hibernate.Transaction;
import ui.common.AbstractUIBean;
import util.HibernateUtil;

/**
 *
 * @author NDH
 */
public class AbstractAdminBean extends AbstractUIBean{
//    Transaction tx;
//    Query q;
//    Session ss = HibernateUtil.getSessionFactory().openSession();
    
    public String create(){
        return "create";
    }
//    public String edit(Object o){
//        return "edit";
//    }
    public String list(){
        return "list";
    }
    public String doupdate(Object o){
        return "list";
    }
    public String docreate(Object o){
        return "list";
    }
     public String find() {
        return "find";
    }

    public AbstractAdminBean() {
//        checkRole();
    }
//    void checkRole(){
//        RoleDAO rDao = new RoleDAO();
//                exContext.redirect(exContext.getRequestContextPath()+"/admin/login.xhtml");
//                HttpServletRequest request = (HttpServletRequest) exContext.getRequest();
//                //request.getRequestURL();
//        }
//    };
     
}
